package com.wanxi.coupon.api.vo;



import com.sun.istack.internal.NotNull;
import com.wanxi.coupon.api.entity.CouponSku;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import java.math.BigDecimal;
import java.util.List;

@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@ApiModel("商家优惠券信息")
public class CouponEnterpriseTDO   {

    @ApiModelProperty(value = "商家id",required = true,example = "1")
    private Long enterpriseId;

    @ApiModelProperty(value = "适用范围",required = true)
    private List<CouponSku> skuRange; //适用范围

    @ApiModelProperty(value = "发放总量",example = "100")
    private Integer quota; //发放总量
    @ApiModelProperty(value = "面额",example = "10")
    private BigDecimal couponMoney; //面额
    @ApiModelProperty(value = "满减额度100，满100减xxx",example = "100")
    private BigDecimal fullReduction; //满减
    @ApiModelProperty(value = "折扣：95 ,打九五折",example = "0.95")
    private BigDecimal discount; //折扣

    @ApiModelProperty(value = "优惠券类型",example = "1")
    private Integer type; //类型

    @ApiModelProperty(value = "优惠券名称",example = "测试")
    private String couponName;
    @ApiModelProperty(value = "描述")
    private String remark; //描述
    @ApiModelProperty(value = "生效时间",required = true,example = "2022-1-1")
    private String startTime; //生效时间
    @NotBlank(message = "失效时间为必填项")
    @ApiModelProperty(value = "失效时间",required = true,example = "2022-1-3")
    private String endTime;  //失效时间

    private Long pastTime;

}
